/**
 * Returns random number inside range
 */
export function rand(min: number, max: number) {
  min = min == null ? Number.MIN_SAFE_INTEGER : min
  max = max == null ? Number.MAX_SAFE_INTEGER : max
  return min + (max - min) * Math.random()
}
